def remove_third(number):
    while number :
        if  len(number) >=3:
            index=2
        else:
            index=2%len(number)
        print(number.pop(index))
list=[10,20,30,40,50,60,70,80,90]
remove_third(list)


